import request from '@/utils/request'

// 获取分类信息
export const getAllCateApi = (params) => {
    return request({
        url: '/ydd_cate/list',
        method: 'get',
        params
    })
}

// 获取标签管理信息
export const getAllTagApi = (params) => {
    return request({
        url: '/ydd_tag/list',
        method: 'get',
        params
    })
}

// 添加信息
export const addCateApi = (data) => {
    return request({
        url: '/ydd_cate/add',
        method: 'post',
        data
    })
}

// 获取单个信息
export const getCateInfoApi = (id) => {
    return request({
        url: '/ydd_cate/rowInfo?id=' + id,
        method: "get",
    })
}

// 修改信息
export const editCateInfoApi = (data) => {
    return request({
        url: "/ydd_cate/update",
        method: "post",
        data
    })
}

// 删除行
export const delCateApi = (id) => {
    return request({
        url: '/ydd_cate/del?id=' + id,
        method: "get"
    })
}
